home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 2010 April / PCWorld0410.iso / hity wydania / Ubuntu 9.10 PL / karmelkowy-koliberek-desktop-9.10-i386-PL.iso / casper / filesystem.squashfs / usr / share / gtksourceview-2.0 / language-specs / styles.rng < prev    next >
Extensible Markup Language  |  2009-10-02  |  3KB  |  139 lines

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!--
  3.  
  4.  Copyright (C) 2006-2007 Yevgen Muntyan <muntyan@tamu.edu>
  5.  
  6.  This library is free software; you can redistribute it and/or
  7.  modify it under the terms of the GNU Library General Public
  8.  License as published by the Free Software Foundation; either
  9.  version 2 of the License, or (at your option) any later version.
  10.  
  11.  This library is distributed in the hope that it will be useful,
  12.  but WITHOUT ANY WARRANTY; without even the implied warranty of
  13.  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  14.  Library General Public License for more details.
  15.  
  16.  You should have received a copy of the GNU Library General Public
  17.  License along with this library; if not, write to the
  18.  Free Software Foundation, Inc., 59 Temple Place - Suite 330,
  19.  Boston, MA 02111-1307, USA.
  20.  
  21. -->
  22. <grammar xmlns="http://relaxng.org/ns/structure/1.0"
  23.          datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
  24.  
  25. <start>
  26.   <element name="style-scheme">
  27.     <attribute name="id">
  28.       <data type="string">
  29.         <param name="pattern">([a-zA-Z0-9_]|-)+</param>
  30.       </data>
  31.     </attribute>
  32.  
  33.     <choice>
  34.       <attribute name="name"/>
  35.       <attribute name="_name"/>
  36.     </choice>
  37.  
  38.     <optional>
  39.       <attribute name="parent-scheme"/>
  40.     </optional>
  41.  
  42.     <attribute name="version">
  43.       <value>1.0</value>
  44.     </attribute>
  45.  
  46.     <optional>
  47.       <oneOrMore>
  48.         <element name="author">
  49.           <text/>
  50.         </element>
  51.       </oneOrMore>        
  52.     </optional>
  53.  
  54.     <optional>
  55.       <choice>
  56.         <element name="description">
  57.           <text/>
  58.         </element>
  59.         <element name="_description">
  60.           <text/>
  61.         </element>
  62.       </choice>
  63.     </optional>
  64.  
  65.     <optional>
  66.       <oneOrMore>
  67.           <element name="color">
  68.               <attribute name="name">
  69.                 <data type="string">
  70.                   <param name="pattern">([a-zA-Z0-9_]|-)+</param>
  71.                 </data>
  72.               </attribute>
  73.               <attribute name="value">
  74.                 <data type="string">
  75.                   <param name="pattern">#.*</param>
  76.                 </data>
  77.               </attribute>
  78.           </element>
  79.       </oneOrMore>
  80.     </optional>
  81.  
  82.     <optional>
  83.       <oneOrMore>
  84.           <element name="style">
  85.               <attribute name="name"/>
  86.  
  87.               <optional>
  88.                 <choice>
  89.                   <attribute name="use-style"/>
  90.                   <ref name="style-elements"/>
  91.                 </choice>
  92.               </optional>
  93.           </element>
  94.       </oneOrMore>
  95.     </optional>
  96.   </element>
  97. </start>
  98.  
  99. <define name="boolean-value">
  100.   <choice>
  101.     <value>true</value>
  102.     <value>false</value>
  103.   </choice>
  104. </define>
  105.  
  106. <define name="style-elements">
  107.   <optional>
  108.     <attribute name="foreground"/>
  109.   </optional>
  110.   <optional>
  111.     <attribute name="background"/>
  112.   </optional>
  113.   <optional>
  114.     <attribute name="line-background"/>
  115.   </optional>
  116.   <optional>
  117.     <attribute name="bold">
  118.       <ref name="boolean-value"/>
  119.     </attribute>
  120.   </optional>
  121.   <optional>
  122.     <attribute name="italic">
  123.       <ref name="boolean-value"/>
  124.     </attribute>
  125.   </optional>
  126.   <optional>
  127.     <attribute name="underline">
  128.       <ref name="boolean-value"/>
  129.     </attribute>
  130.   </optional>
  131.   <optional>
  132.     <attribute name="strikethrough">
  133.       <ref name="boolean-value"/>
  134.     </attribute>
  135.   </optional>
  136. </define>
  137.  
  138. </grammar>
  139.